package object;

import java.util.Objects;

public class Point {
    private String nmae;
    private int age;
    private int id;

    public Point(String nmae, int age, int id) {
        this.nmae = nmae;
        this.age = age;
        this.id = id;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Point point = (Point) o;
        return age == point.age && id == point.id && Objects.equals(nmae, point.nmae);
    }

    @Override
    public int hashCode() {
        return Objects.hash(nmae, age, id);
    }

    @Override
    public String toString() {
        return "Point{" +
                "nmae='" + nmae + '\'' +
                ", age=" + age +
                ", id=" + id +
                '}';
    }

    public String getNmae() {
        return nmae;
    }

    public void setNmae(String nmae) {
        this.nmae = nmae;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }
}
